package com.lhkj.ct.base.model.dto;

import org.apache.commons.lang3.StringUtils;

import java.io.Serializable;


@Deprecated
public class OrderItem implements Serializable {

    private String orderByColumn;

    private String isAsc;

    public String getOrderByColumn() {
        return orderByColumn;
    }

    public void setOrderByColumn(String orderByColumn) {
        this.orderByColumn = orderByColumn;
    }

    public String getIsAsc() {
        return isAsc;
    }

    public void setIsAsc(String isAsc) {
        this.isAsc = isAsc;
    }

    public boolean isAsc() {
        if (StringUtils.isNotEmpty(isAsc)) {
            // 兼容前端排序类型
            if ("ascending".equals(isAsc)) {
                return true;
            } else if ("descending".equals(isAsc)) {
                return false;
            }
        }
        return false;
    }
}
